package com.baway.cache

import kotlinx.coroutines.flow.Flow

/**
 * Author: Jason Zhang
 * Date: 2025/9/13
 * Desc: 定义统一的接口方法
 */
interface ICache {
    /**
     * 定义存储方法
     */
    fun putString(key: String, value: String)
    fun putInt(key: String, value: Int)
    fun putLong(key: String, value: Long)
    fun putBool(key: String, value: Boolean)

    /**
     * 定义获取方法
     */
    fun getString(key: String): Flow<String>
    fun getInt(key: String): Flow<Int>
    fun getLong(key: String): Flow<Long>
    fun getBool(key: String): Flow<Boolean>

}